if isAuthenticated
    if shouldShowHomePage
        div.container
            div.row
                div.col-sm-6.col-md-4.col-md-offset-4
                    h1.text-center.login-title All homeworks:
                        table(class = "table table-hover")
                            thead
                                tr 
                                    th 名称
                                    th 截止时间
                            tbody
                                each homeworks
                                    tr
                                        th <a href='/' name = "#{_id}" class = "show-homework">#{title}</a>
                                        th #{deadline}
                    if isTeacher
                        a(href='/', class='text-center publish-homework') Publish Homework